package com.song.study.spring.Entity;

import com.sun.media.jfxmediaimpl.MediaDisposer;
import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.NoArgsConstructor;
import org.springframework.beans.factory.DisposableBean;
import org.springframework.beans.factory.InitializingBean;
import org.springframework.stereotype.Component;

/**
 * @Author ZhangGuisong
 * @Date 2021/4/24-19:56
 */
@Component
@Data
@AllArgsConstructor
@NoArgsConstructor
public class Lion implements InitializingBean, DisposableBean {
    private String name;

    @Override
    public void destroy() throws Exception {
        System.out.println("Lion is destroy");
    }

    @Override
    public void afterPropertiesSet() throws Exception {
        System.out.println("lion had setProperties");
    }
}
